
import { getUserInfoUrl } from "@/command/apiTool";
import { useDetail, useList } from "@/hooks";
import { getAction, postAction } from "@/command/netTool";
import { reactive, watch } from "vue";
import { useRoute } from "vue-router";

export const useRequest = () => {
    const form = reactive({
        pageNo: 1,

    })
    const route = useRoute()
    //
    const [WorkInfo, useHistoryListControl] = useDetail(
        getUserInfoUrl({
            dh: "",
            xh: "/api/H5/service/helpWork/small/getWorkInfoById",
        }, { id: route.query.id }),
        {
            address: "",
            applyFlag: "",
            area: "",
            id: "",
            lat: "",
            lng: "",
            logoUrl: "",
            teamFlag: "",
            title: "",
            town: "",
            userId: "",
            userName: "",
            workDay: "",
            workName: "",
            workPrice: "",
            workType: ""
        }

        // {
        //     "code": 0,
        //     "data": {
        //         "count": 0,
        //         "otherData": {},
        //         "pageNo": 0,
        //         "pageSize": 0
        //     },
        //     "msg": "",
        //     "status": 0
        // }
    );

    return {
        WorkInfo, form,
    }
}